import RouterView from "@/components/MyRouterView/index.vue";
/**
 * 所有组件都在 @/views/nav/nav001/下
 * 命名都需要按照这个规则配置
 * name 记录了路由细信息
 */
export default [
  {
    path: "/nav002",
    name: "nav002",
    meta: { title: "封装" },
    component: RouterView,
    redirect: "/nav002/bar001/page001",
    children: [
      {
        path: "bar001",
        name: "nav002bar001",
        meta: { title: "01 官网案例" },
        component: RouterView,
        redirect: "/nav002/bar001/page001",
        children: [
          {
            path: "page001",
            name: "nav002bar001page001",
            meta: { title: "01.加载高德地图" },
            component: () =>
              import("@/views/nav/nav002/bar001/page001/index.vue"),
          },
          {
            path: "page002",
            name: "nav002bar001page002",
            meta: { title: "02.点击弹框" },
            component: () =>
              import("@/views/nav/nav002/bar001/page002/index.vue"),
          },
        ],
      },
      {
        path: "bar002",
        name: "nav002bar002",
        meta: { title: "02. 封装" },
        component: RouterView,
        redirect: "/nav002/bar002/page001",
        children: [
          {
            path: "page001",
            name: "nav002bar002page001",
            meta: { title: "01.封装点击弹框" },
            component: () =>
              import("@/views/nav/nav002/bar002/page001/index.vue"),
          },
          {
            path: "page002",
            name: "nav002bar002page002",
            meta: { title: "02.绘图工具封装绘图方法-" },
            component: () =>
              import("@/views/nav/nav002/bar002/page002/index.vue"),
          },
          {
            path: "page003",
            name: "nav002bar002page003",
            meta: { title: "03.进一步封装弹窗" },
            component: () =>
              import("@/views/nav/nav002/bar002/page003/index.vue"),
          },
        ],
      },
    ],
  },
];
